package org.example.lease.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;

import org.example.lease.mapper.ViewAppointmentMapper;
import org.example.lease.model.entities.ViewAppointment;
import org.example.lease.service.ViewAppointmentService;
import org.example.lease.vo.appointment.AppointmentQueryVo;
import org.example.lease.vo.appointment.AppointmentVo;
import org.springframework.stereotype.Service;


/**
 * @author 宋孟林
 * @description
 * @date: 2025/5/12 16:52
 */
@Service
@Slf4j
public class ViewAppointmentServiceImpl extends ServiceImpl<ViewAppointmentMapper, ViewAppointment> implements ViewAppointmentService {
    @Resource
    private ViewAppointmentMapper viewAppointmentMapper;

    @Override
    public IPage<AppointmentVo> selectAppointmentVoByQuery(IPage<AppointmentVo> page, AppointmentQueryVo appointmentQueryVo) {
        IPage<AppointmentVo> appointmentVoIPage = viewAppointmentMapper.selectAppointmentVoByQuery(page, appointmentQueryVo);
        log.info("appointmentVoList已经查出记录是：{}", appointmentVoIPage.getRecords());
        return appointmentVoIPage;
    }
}




